package edu.ynu.se.xiecheng.dto;

import lombok.Data;
import java.time.LocalDateTime;
import java.math.BigDecimal;

@Data
public class SensorDataDTO {
    private Long deviceId;
    private LocalDateTime collectTime;
    private DataPoint nitrogen;
    private DataPoint phosphorus;
    private DataPoint potassium;
    private DataPoint soilTemperature;
    private DataPoint soilMoisture;
    private DataPoint conductivity;
    private DataPoint phValue;
    private DataPoint lightIntensity;
    private DataPoint co2;
    private DataPoint airTemperature;
    private DataPoint airHumidity;

    @Data
    public static class DataPoint {
        private BigDecimal value;
        private String unit;
        private String label;

        public DataPoint(BigDecimal value, String unit, String label) {
            this.value = value;
            this.unit = unit;
            this.label = label;
        }
    }
} 